﻿using LuaInterface;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class LuaScript : MonoBehaviour {

    public string m_LuaFile;

    private LuaState m_Lua;
    void Awake(){
        //创建lua机
//         m_Lua = new LuaState();
//         m_Lua.Start();
//         //映射unity类
//         LuaBinder.Bind(m_Lua);
//         DelegateFactory.Init();
//         //添加lua文件
//         string fullPath = Application.dataPath + "\\Lua";
//         m_Lua.AddSearchPath(fullPath);
//         //调用lua文件
//         m_Lua.DoFile(m_LuaFile);//可多次调用
    }
    // Use this for initialization
    void Start () {
        
    }
	
	// Update is called once per frame
	void Update () {
		
	}

    private void OnDestroy()
    {
//         //销毁lua文件
//         m_Lua.Dispose();
//         m_Lua = null;
    }
}
